.popular-content-container {
  padding: 0;
  background: #f5f7fa;
  min-height: calc(100vh - 64px);

  // 统计卡片
  .stats-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 16px;

    .stat-card {
      border-radius: 8px;
      box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
      transition: all 0.3s ease;

      &:hover {
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        transform: translateY(-2px);
      }

      .ant-card-body {
        padding: 20px;
      }

      .stat-content {
        display: flex;
        justify-content: space-between;
        align-items: center;

        .stat-info {
          .stat-label {
            font-size: 14px;
            color: #8c8c8c;
            margin-bottom: 8px;
          }

          .stat-value {
            font-size: 28px;
            font-weight: 600;
            color: #262626;
          }
        }

        .stat-icon {
          width: 56px;
          height: 56px;
          border-radius: 12px;
          display: flex;
          align-items: center;
          justify-content: center;
          font-size: 24px;

          &.books {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: #fff;
          }

          &.readers {
            background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
            color: #fff;
          }

          &.views {
            background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
            color: #fff;
          }

          &.rating {
            background: linear-gradient(135deg, #ffd89b 0%, #19547b 100%);
            color: #fff;
          }
        }
      }
    }
  }

  // 排行榜卡片
  .ranking-card {
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);

    .ranking-header {
      display: flex;
      justify-content: space-between;
      align-items: center;
      margin-bottom: 24px;

      h3 {
        font-size: 18px;
        font-weight: 600;
        color: #262626;
        margin: 0;
      }
    }

    .ant-tabs {
      .ant-tabs-tab {
        font-size: 15px;
        padding: 12px 16px;

        .anticon {
          margin-right: 6px;
        }
      }
    }

    .ant-table {
      // 表格滚动条样式
      .ant-table-container {
        .ant-table-body,
        .ant-table-content {
          scrollbar-width: thin;
          scrollbar-color: #d9d9d9 transparent;
          scrollbar-gutter: stable;

          &::-webkit-scrollbar {
            width: 8px;
            height: 8px;
          }

          &::-webkit-scrollbar-track {
            background: #f0f0f0;
            border-radius: 4px;
          }

          &::-webkit-scrollbar-thumb {
            background: #d9d9d9;
            border-radius: 4px;
            
            &:hover {
              background: #bfbfbf;
            }
          }

          &::-webkit-scrollbar-corner {
            background: transparent;
          }
        }
      }

      .ant-table-thead > tr > th {
        background: #fafafa;
        font-weight: 600;
        color: #262626;
        border-bottom: 2px solid #f0f0f0;
        padding: 16px;
      }

      .ant-table-tbody > tr {
        transition: all 0.3s ease;

        &:hover {
          background: #f5f7fa;

          td {
            background: transparent;
          }
        }

        td {
          padding: 16px;
          border-bottom: 1px solid #f5f5f5;
        }
      }

      // 排名徽章
      .rank-badge {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 4px;
        font-size: 18px;
        font-weight: 600;

        .anticon {
          font-size: 20px;
        }
      }

      .rank-number {
        font-size: 16px;
        font-weight: 600;
        color: #595959;
      }

      // 图书信息单元格
      .book-info-cell {
        display: flex;
        align-items: center;
        gap: 12px;

        .book-cover {
          flex-shrink: 0;
          width: 50px;
          height: 70px;
          border-radius: 4px;
          overflow: hidden;
          box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);

          img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
          }
        }

        .book-details {
          display: flex;
          flex-direction: column;
          gap: 6px;
          min-width: 0;
          flex: 1;

          .book-name {
            font-size: 15px;
            font-weight: 600;
            color: #262626;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
          }

          .book-meta {
            display: flex;
            align-items: center;
            gap: 8px;
            font-size: 13px;
            color: #8c8c8c;
          }
        }
      }

      // 读者信息单元格
      .reader-info-cell {
        display: flex;
        align-items: center;
        gap: 12px;

        .ant-avatar {
          flex-shrink: 0;
          background: #1890ff;
        }

        .reader-details {
          display: flex;
          flex-direction: column;
          gap: 2px;
          min-width: 0;
          flex: 1;

          .reader-name {
            font-size: 14px;
            font-weight: 500;
            color: #262626;
          }

          .reader-id {
            font-size: 12px;
            color: #8c8c8c;
          }
        }
      }

      // 统计单元格
      .stat-cell {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 4px;
        font-size: 14px;
        font-weight: 500;
      }

      // 评分单元格
      .rating-cell {
        display: flex;
        justify-content: center;
      }

      .rating-score {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 4px;
        font-size: 16px;
        font-weight: 600;
        color: #faad14;
      }

      // 趋势单元格
      .trend-cell {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 4px;
        font-weight: 600;

        .anticon {
          font-size: 16px;
        }
      }

      // 高亮数字
      .highlight-number {
        font-size: 15px;
        font-weight: 600;
        color: #1890ff;
      }

      // 分类名称
      .category-name {
        font-size: 15px;
        font-weight: 600;
        color: #262626;
      }

      .ant-tag {
        border-radius: 4px;
        padding: 2px 8px;
        font-size: 12px;
        border: none;
      }
    }
  }

  // 响应式设计
  @media (max-width: 1200px) {
    .stats-cards {
      grid-template-columns: repeat(2, 1fr);
    }
  }

  @media (max-width: 768px) {
    padding: 16px;

    .stats-cards {
      grid-template-columns: 1fr;
    }

    .ranking-card {
      .ant-card-body {
        padding: 16px;
      }

      .ranking-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;

        h3 {
          text-align: center;
        }
      }

      .ant-table {
        .book-info-cell {
          gap: 8px;

          .book-cover {
            width: 40px;
            height: 56px;
          }

          .book-details {
            .book-name {
              font-size: 14px;
            }

            .book-meta {
              font-size: 12px;
            }
          }
        }

        .reader-info-cell {
          gap: 8px;

          .ant-avatar {
            width: 32px !important;
            height: 32px !important;
          }

          .reader-details {
            .reader-name {
              font-size: 13px;
            }

            .reader-id {
              font-size: 11px;
            }
          }
        }
      }
    }
  }

  @media (max-width: 480px) {
    .stats-cards {
      .stat-card {
        .stat-content {
          .stat-info {
            .stat-value {
              font-size: 24px;
            }
          }

          .stat-icon {
            width: 48px;
            height: 48px;
            font-size: 20px;
          }
        }
      }
    }
  }
}
